package com.ruoyi.ring.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.Date;

/**
 * 群组对象 az_ring_group
 * 
 * @author liuwp
 * @date 2025-10-20
 */
@Data
public class RingGroup extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键ID */
    private Long id;

    /** 用户id */
    @Excel(name = "用户id")
    private Long userId;

    /** 设备sn */
    @Excel(name = "设备sn")
    private String deviceSn;

    /** 群组名称 */
    @Excel(name = "群组名称")
    private String groupName;

    /** 群组创建人 */
    @Excel(name = "群组创建人")
    private String groupCreator;

    /** 群组码 */
    @Excel(name = "群组码")
    private String groupCode;

    /** 群组排序时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "群组排序时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date groupSortTime;

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("userId", getUserId())
            .append("deviceSn", getDeviceSn())
            .append("groupName", getGroupName())
            .append("groupCreator", getGroupCreator())
            .append("groupCode", getGroupCode())
            .append("remark", getRemark())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
